import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';

import { AppComponent } from './app.component';
import { FooterComponent } from './footer/footer.component';
import { SearchComponent } from './search/search.component';
import { CarouselComponent } from './carousel/carousel.component';
import { ProductComponent } from './product/product.component';
import { StarsComponent } from './stars/stars.component';
import { NavbarComponent } from './navbar/navbar.component';
import { ProducrDetailsComponent } from './producr-details/producr-details.component';
import { HomeComponent } from './home/home.component';
import { AppRoutingModule } from "./app-routing.module";
import { ProductService } from "./shared/product.service";
import { FormsModule, ReactiveFormsModule } from "@angular/forms";
import { FilterPipe } from './pipe/filter.pipe';
import { HttpModule } from "@angular/http";
import { WebSocketService } from "./shared/web-socket.service";
import { HashLocationStrategy, LocationStrategy } from "@angular/common";

@NgModule ({
    declarations : [
        AppComponent,
        FooterComponent,
        SearchComponent,
        CarouselComponent,
        ProductComponent,
        StarsComponent,
        NavbarComponent,
        ProducrDetailsComponent,
        HomeComponent,
        FilterPipe
    ],
    imports : [
        BrowserModule,
        AppRoutingModule,
        FormsModule,
        HttpModule,
        ReactiveFormsModule
    ],
    providers : [
        ProductService,
        WebSocketService,
        {
            provide : LocationStrategy,
            useClass : HashLocationStrategy
        }
    ],
    bootstrap : [AppComponent]
})
export class AppModule {


}
